const defaultState = {
  newsList: [],
  name: "joah li"
}

const homeReducer = (state = defaultState, action) => {

  switch (action.type) {
    case "changeHomeList":
      // console.log("------------")
      // console.log(action.data);
      return {
        ...state,
        newsList: action.data
      }
    default:
      return state
  }
}

export default homeReducer